﻿using System;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
using ESoft.DataAccess.EfCore;
using ESoft.DataAccess.Models;
using Microsoft.EntityFrameworkCore.Metadata.Builders;

namespace SampleWeb.Data.Models
{
    /// <summary>
    /// GGoods
    /// </summary>    
	[Table("g_goods")]
    public partial class GGoodsEntity : EntityBase
    {
        /// <summary>
        /// 
        /// </summary>
        [Key]
        [Column("GOODS_ID")]
        public string GoodsId { get; set; }
        /// <summary>
        /// 货物名称
        /// </summary> 
        [Column("GOODS_NAME")]
        public string GoodsName { get; set; }
        /// <summary>
        /// 零售价
        /// </summary> 
        [Column("SALE_PRICE")]
        public decimal SalePrice { get; set; }
        /// <summary>
        /// 货架ID
        /// </summary> 
        [Column("SHELF_ID")]
        public string ShelfId { get; set; }
        /// <summary>
        /// 详情信息
        /// </summary> 
        [Column("DETAIL_TEXT_ID")]
        public string DetailTextId { get; set; }
        /// <summary>
        /// 机构标识
        /// </summary> 
        [Column("ORG_ID")]
        public string OrgId { get; set; }
        /// <summary>
        /// 创建时间
        /// </summary> 
        [Column("CREATE_DATETIME")]
        public DateTime? CreateDatetime { get; set; }
        /// <summary>
        /// 创建人
        /// </summary> 
        [Column("CREATE_USER_ID")]
        public string CreateUserId { get; set; }
        /// <summary>
        /// 是否包邮，0否1是
        /// </summary> 
        [Column("IS_FREE_SHIPPING")]
        public string IsFreeShipping { get; set; }
        /// <summary>
        /// 1未上架2上架3下架
        /// </summary> 
        [Column("STATUS")]
        public int? Status { get; set; }
        /// <summary>
        /// 状态时间
        /// </summary> 
        [Column("STATUS_DATETIME")]
        public DateTime? StatusDatetime { get; set; }
    }

    public class GGoodsConfiguration : EntityMappingConfiguration<GGoodsEntity>
    {
        public override void Map(EntityTypeBuilder<GGoodsEntity> b)
        {
        }
    }
}

